import { _decorator, Component } from 'cc';
import { Ins } from '../Ins';
const { ccclass, property } = _decorator;

@ccclass('BaseLayer')
export class BaseLayer extends Component {
    isFade: boolean = true

    show() {
        this.node.active = true
    }

    hide() {
        this.node.active = false
    }

    onDisable() {
        if (Ins.FadeMgr.isActive && this.isFade) Ins.FadeMgr.fadeOut()
    }
}


